import ollama

question = input("请输入问题：") or "20字介绍北京"

response = ollama.embed(
    # model="mxbai-embed-large",  
    model="all-minilm:33m",
    # input=question,
    input=[question,"介绍京津冀"]  # batch模式
)

print(response.embeddings) #response['embeddings']  # 或者resoponse.embeddings


import numpy as np
data=np.array(response.embeddings)
print(data.shape)